import Vue from 'vue'
import App from './App'

Vue.config.productionTip = false

App.mpType = 'app'
//储存
import { localStorage, sessionStorage } from 'sdk/mp-storage/index.js'
Vue.prototype.$localStorage=localStorage
Vue.prototype.sessionStorage=localStorage


//坐标
let coordtransform=require('coordtransform');
Vue.prototype.coor=coordtransform

Vue.prototype.goback=function(){
	console.log('执行返回')
	uni.navigateBack({
		delta: 1
	});
}


Vue.prototype.gopage=function(name){
	
	if(name=='#'){
		return false
	}
	
	if(name=='index'||name=='list'){
		uni.switchTab({
			url: '/pages/'+name+'/'+name
		});
	}else{
		uni.navigateTo({
			url: '/pages/'+name
		});
	}
	
		
	
}



const app = new Vue({
    ...App
})
app.$mount()
